package com.group3.hospital.service.impl;/*
 *@author 时崎
 * 2022/01/03
 */

import com.group3.hospital.bean.Subject;
import com.group3.hospital.mapper.SubjectMapper;
import com.group3.hospital.service.SubjectService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class SubjectServiceImpl implements SubjectService {
    @Resource
    private SubjectMapper subjectMapper;

    @Override
    public List<Subject> showNoOpe() throws Exception {
        return subjectMapper.showNoOpe();
    }

    @Override
    public List<Subject> showOpe() throws Exception {
        return subjectMapper.showOpe();
    }

    @Override
    public List<Subject> showDiagnosis() throws Exception {
        return subjectMapper.showDiagnosis();
    }

    @Override
    public Subject queryByName(String subjectName) throws Exception {
        return subjectMapper.queryByName(subjectName);
    }

    @Override
    public void deleteById(Integer subjectId) throws Exception {
        subjectMapper.deleteById(subjectId);
    }

    @Override
    public void update(Subject sub) throws Exception {
        subjectMapper.update(sub);
    }


}
